import { GSprite } from "../../../../../../com/mui/controls/GSprite";
import { ObjCreate } from "../../../common/ObjCreate";
import { GlobalStyle } from "../../../../../common/global/GlobalStyle";
import { Language } from "../../../../../../extend/language/Language";
import { ImagesConst } from "../../../../resource/ImagesConst";
import { HTMLUtil } from "../../../../../../com/gengine/utils/HTMLUtil";
import { ScaleBitmap } from "../../../../../../com/mui/display/ScaleBitmap";
import { GTextArea } from "../../../../../../com/mui/controls/GTextArea";
//class GuildUnionRulePanel
    
    export  class GuildUnionRulePanel extends GSprite
    {
        constructor()
        {
            super();
            this.initUI();
            return;
        }

        /* internal  */initUI(): void
        {
            this._bg = ObjCreate.createBg(0, 0, 230, 430, this);
            var loc1=GlobalStyle.getTextFormatCenter(GlobalStyle.textFormat6);
            loc1.size = 14;
            ObjCreate.createGTextField(Language.getString(60884), 0, 10, 230, 20, this, loc1);
            ObjCreate.createBg(5, 33, 220, 2, this, ImagesConst.SplitLine);
            this._ruleText = ObjCreate.createTextArea("", 10, 40, 210, 380, this);
            flash.utils.setTimeout(this.calllater, 200);
            var loc2=Language.getString(60878) + "\n" + Language.getString(60879) + "\n" + Language.getString(60880);
            this._ruleText.htmlText = HTMLUtil.addColor(loc2, GlobalStyle.color1);
            return;
        }

        /* internal  */calllater(): void
        {
            this._ruleText.setStyle("textFormat", GlobalStyle.setTextFormatLeading(GlobalStyle.textFormat1, 5));
            return;
        }

        /* internal */ /* var */_bg: ScaleBitmap;

        /* internal */ /* var */_ruleText: GTextArea;
    }
